$new-smart-contract-container-tooltips-background-color: #fbfafc !default;
$new-smart-contract-tooltips-width: 300px;
$smart-contract-form-group-tooltip-color: #adb5bd !default;
$new-smart-contract-center-column-margin-right: 30px;

.new-smart-contract-container {
  background-color: #fff;
  background-image: linear-gradient(
    to bottom right,
    #{$new-smart-contract-container-tooltips-background-color} 100%,
    #{$new-smart-contract-container-tooltips-background-color} 100%
  );
  background-position: 100% 0;
  background-repeat: repeat-y;
  background-size: #{$new-smart-contract-tooltips-width} 1px;
  box-shadow: 0 0 25px 0 rgba(0, 0, 0, 0.15);
  margin-bottom: 3rem;
  padding: 50px 0 50px 22px;

  @include media-breakpoint-down(md) {
    background-image: none;
    padding-right: 22px;
  }
}

.smart-contract-title {
  color: #333;
  font-size: 18px;
  font-weight: normal;
  line-height: 1.2;
  margin: 0 0 70px 0;
  padding: 0;
  text-align: left;

  @include media-breakpoint-down(md) {
    margin-bottom: 30px;
  }

  &.margin-bottom-md {
    margin-bottom: 50px;

    @include media-breakpoint-down(md) {
      margin-bottom: 15px;
    }
  }
}

.smart-contract-form-group {
  margin-bottom: 30px;

  @include media-breakpoint-down(md) {
    margin-bottom: 20px;
  }
}

.form-radios-group {
  display: flex;
  justify-content: flex-start;

  .radio-big {
    margin-right: 20px;

    &:last-child {
      margin-right: 0;
    }
  }
}

.smart-contract-form-group-inner-wrapper {
  display: flex;
  justify-content: space-between;

  @include media-breakpoint-down(md) {
    flex-direction: column;
  }

  > label {
    color: #333;
    flex-grow: 0;
    font-size: 14px;
    font-weight: normal;
    line-height: 1.7;
    margin: 0;
    padding-right: 15px;
    text-align: left;
    width: 200px;

    @include media-breakpoint-down(md) {
      margin-bottom: 10px;
      padding-right: 0;
      width: auto;
    }
  }

  .center-column {
    flex-grow: 1;
    margin-right: $new-smart-contract-center-column-margin-right;

    @include media-breakpoint-down(md) {
      margin: 0;
    }
  }

  textarea.form-control {
    min-height: 98px;
  }

  .form-error {
    display: block;
    font-size: 13px;
    line-height: 1.2;
    padding-top: 10px;
  }

  .smart-contract-form-group-tooltip {
    color: $smart-contract-form-group-tooltip-color;
    flex-grow: 0;
    flex-shrink: 0;
    font-size: 12px;
    font-weight: normal;
    line-height: 1.5;
    padding: 0 30px;
    text-align: left;
    width: #{$new-smart-contract-tooltips-width};

    @include media-breakpoint-down(md) {
      padding: 10px 0 0 0;
      width: auto;
    }

    &:empty {
      @include media-breakpoint-down(md) {
        display: none;
      }
    }

    a {
      color: $smart-contract-form-group-tooltip-color;
      text-decoration: underline;

      &:hover {
        text-decoration: none;
      }
    }
  }
}

.tooltip-quote {
  background: rgba(0, 0, 0, 0.08);
  border-radius: 2px;
  padding: 0 5px;
}


.add-contract-libraries-wrapper {
  border-bottom: 1px solid $base-border-color;
  margin-right: $new-smart-contract-center-column-margin-right + $new-smart-contract-tooltips-width;
  padding-bottom: 30px;

  @include media-breakpoint-down(md) {
    margin-right: 0;
  }
}

.smart-contract-form-buttons {
  align-items: center;
  border-top: 1px solid $base-border-color;
  display: flex;
  margin-right: $new-smart-contract-center-column-margin-right + $new-smart-contract-tooltips-width;
  margin-top: -1px;
  padding-top: 30px;
  position: relative;

  @include media-breakpoint-down(md) {
    margin-right: 0;
  }

  [class*="btn-"] {
    position: relative;
    z-index: 1;
  }

  .position-absolute {
    &,
    &:hover {
      opacity: 1;
      z-index: 12;
    }
  }
}

.smart-contract-libraries-wrapper {
  display: none;
  padding-bottom: 30px;
  padding-top: 30px;
}

.contract-library-form-group {
  display: none;

  &.active {
    display: block;
  }
}